package com.hs.sfzy.service.impl;

import com.hs.sfzy.entity.CourseRating;
import com.hs.sfzy.mapper.CourseRatingMapper;
import com.hs.sfzy.service.CourseRatingService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @ClassName CourseRatingServiceImpl
 * @Description TODO
 * @Author Chen
 * @Date 2025年08月13日 15:02
 * @Version 1.0
 */
@Service
public class CourseRatingServiceImpl implements CourseRatingService {
    @Autowired
    private CourseRatingMapper courseRatingMapper;

    @Override
    public List<CourseRating> getAllCourseRating(Integer courseId) {
        return courseRatingMapper.getAllCourseRating(courseId);
    }

    @Override
    public Integer addCourseRating(CourseRating courseRating) {
        return courseRatingMapper.addCourseRating(courseRating);
    }
}
